const user = doodoo.bookshelf.Model.extend({
    tableName: "user",
    hasTimestamps: true
});

const subComment = doodoo.bookshelf.Model.extend({
    tableName: "shop_order_comment",
    hasTimestamps: true
});

module.exports = doodoo.bookshelf.Model.extend({
    tableName: "shop_order_comment",
    hasTimestamps: true,
    user: function() {
        return this.belongsTo(user, "user_id");
    },
    subComment: function() {
        return this.hasOne(subComment, "pid");
    }
});
